<template>
  <el-dialog :title="title" :close-on-click-modal="false" :visible.sync="visible" width="800px" append-to-body :before-close="handleClose">
    <trouble-shoot-detail :form="form" :dataStatus="form.dataStatus"></trouble-shoot-detail>
    <div slot="footer" class="dialog-footer">
      <el-button @click="cancel">关 闭</el-button>
    </div>
  </el-dialog>
</template>

<script>
import { listCommonCheckType } from '@/api/cases/commonCheckType'
import TroubleShootDetail from '../Detail/troubleShootDetail.vue';

export default {
  components:{TroubleShootDetail},
  dicts: ["jl_cases_damage_level", "jl_cases_repair_method", "jl_data_status", "jl_measurement_unit","jl_case_unit"],
  data() {
    return {
      visible: false,
      isDisabled: true,
      form: {},
      checkTypes:[]
    }
  },
  props: {
    title: String,
    default: ""
  },
  methods: {
    /**
     * 打开
     */
    open(form){
        this.visible = true;
        this.form = form;
    },
    /**
     * 处理关闭
     */
    handleClose() {
      this.cancel();
    },
    /**
     * 隐藏
     */
    cancel() {
      this.visible = false;
    },
  }
}
</script>

<style lang="scss" scoped>
.form-title {
  padding: 2px 0;
  border-bottom: 1px solid #eee;
  margin-bottom: 10px;
}
.input-sperator {
  margin-right: 10px;
  margin-left: 10px;
  padding-bottom: 18px;
  line-height: 29px;
}
</style>